﻿<common:LayoutAwarePage
    x:Name="pageRoot"
    x:Class="FoodandDining.Filter"
    DataContext="{Binding DefaultViewModel, RelativeSource={RelativeSource Self}}"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:FoodandDining"
    xmlns:common="using:FoodandDining.Common"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Page.Resources>

        <!-- TODO: Delete this line if the key AppName is declared in App.xaml -->
        <x:String x:Key="AppName">My Application</x:String>
    </Page.Resources>

    <!--
        This grid acts as a root panel for the page that defines two rows:
        * Row 0 contains the back button and page title
        * Row 1 contains the rest of the page layout
    -->
    <!--
        This grid acts as a root panel for the page that defines two rows:
        * Row 0 contains the back button and page title
        * Row 1 contains the rest of the page layout
    -->
    <!--
        This grid acts as a root panel for the page that defines two rows:
        * Row 0 contains the back button and page title
        * Row 1 contains the rest of the page layout
    -->
    <Grid Style="{StaticResource LayoutRootStyle}" Width="370" HorizontalAlignment="Left" Background="#FFFB4732">
        <Grid.RowDefinitions>
            <RowDefinition Height="140"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <VisualStateManager.VisualStateGroups>

            <!-- Visual states reflect the application's view state -->
            <VisualStateGroup x:Name="ApplicationViewStates">
                <VisualState x:Name="FullScreenLandscape"/>
                <VisualState x:Name="Filled"/>

                <!-- The entire page respects the narrower 100-pixel margin convention for portrait -->
                <VisualState x:Name="FullScreenPortrait">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="backButton" Storyboard.TargetProperty="Style">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource PortraitBackButtonStyle}"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>

                <!-- The back button and title have different styles when snapped -->
                <VisualState x:Name="Snapped">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="backButton" Storyboard.TargetProperty="Style">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource SnappedBackButtonStyle}"/>
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="pageTitle" Storyboard.TargetProperty="Style">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource SnappedPageHeaderTextStyle}"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>

        <!-- Back button and page title -->
        <Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="Auto"/>
                <ColumnDefinition Width="*"/>
            </Grid.ColumnDefinitions>
            <Button x:Name="backButton" Click="GoBack" IsEnabled="{Binding Frame.CanGoBack, ElementName=pageRoot}" Style="{StaticResource BackButtonStyle}" Visibility="Collapsed"/>
            <TextBlock x:Name="pageTitle" Grid.Column="1" Style="{StaticResource PageHeaderTextStyle}" Text="Filter By" Margin="35,0,5,40" Foreground="#FF050708" FontSize="40"/>
        </Grid>
        <StackPanel Grid.Row="1" Margin="40,0,0,0">
        	<RadioButton x:Name="rbtnVegetarian" Content="Vegetarian" VerticalAlignment="Stretch" FontSize="16" FontWeight="Light" Foreground="Black" Style="{StaticResource FilterRadioButtonStyle}" Padding="5,4,0,0"/>
        	<RadioButton x:Name="rbtnNonVegetarian" Content="Non- Vegetarian" VerticalAlignment="Stretch" FontSize="16" FontWeight="Light" Foreground="Black" Style="{StaticResource FilterRadioButtonStyle}" Padding="5,4,0,0" Margin="0,5,0,0"/>
        	<TextBlock x:Name="txtCuisine" TextWrapping="Wrap" Text="Cuisine" Margin="0,20,0,5" FontSize="13.333" FontFamily="Segoe UI" FontWeight="Light"/>
        	<ComboBox x:Name="cbxCuisine" Width="240" HorizontalAlignment="Left" SelectedIndex="0" Style="{StaticResource ComboBoxStyle}" BorderBrush="#FFF69679" Background="#FFF69679" Foreground="#FFFB725A">
        		<ComboBoxItem x:Name="cbxItmBengali" Content="Bengali" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmSouthIndian" Content="South Indian" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmGujrati" Content="Gujrati" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmRajasthani" Content="Rajasthani" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmGoan" Content="Goan" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmJain" Content="Jain" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmMaharashtrian" Content="Maharashtrian" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        	</ComboBox>
        	<TextBlock x:Name="txtIngredients" TextWrapping="Wrap" Text="Ingredients" Margin="0,20,0,5" FontSize="13.333" FontFamily="Segoe UI" FontWeight="Light"/>
        	<ComboBox x:Name="cbxIngredients" Width="240" HorizontalAlignment="Left" SelectedIndex="0" Style="{StaticResource ComboBoxStyle}" BorderBrush="#FFF69679" Background="#FFF69679" Foreground="#FFFB725A">
        		<ComboBoxItem x:Name="cbxItmFish" Content="Fish" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmMeat" Content="Meat" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmEgg" Content="Egg" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmPotato" Content="Potato" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmPaneer" Content="Paneer" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmGravy" Content="Gravy" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        		<ComboBoxItem x:Name="cbxItmPrawns" Content="Maharashtrian" Style="{StaticResource ComboBoxItemStyle}" Foreground="Black"/>
        	</ComboBox>
        	<StackPanel x:Name="spSweet" Orientation="Horizontal" HorizontalAlignment="Left" Margin="0,30,0,0">
        		<RadioButton x:Name="rbtnSweet" Content="Sweet" VerticalAlignment="Stretch" FontSize="16" FontWeight="Light" Foreground="Black" Style="{StaticResource FilterRadioButtonStyle}" Padding="5,4,0,0"/>
        		<RadioButton x:Name="rbtnSavoury" Content="Savoury" VerticalAlignment="Stretch" FontSize="16" FontWeight="Light" Foreground="Black" Style="{StaticResource FilterRadioButtonStyle}" Padding="5,4,0,0" Margin="76,0,0,0"/>
        	</StackPanel>
        	<Button x:Name="btnFilter" Content="Filter" HorizontalAlignment="Left" VerticalAlignment="Stretch" Margin="0,20,0,0" Background="#FF050708" BorderBrush="#FF050708" BorderThickness="0" Style="{StaticResource FilterButtonStyle}" FontSize="21.333" FontWeight="Light" Foreground="#FFFF5440" Padding="30,5"/>
        </StackPanel>

    </Grid>
</common:LayoutAwarePage>
